
package org.wk.upms.controller;


import org.apache.shiro.SecurityUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.wk.upms.view.ManagerVo;

/**
 * Controller公共组件
 */
public abstract class AbstractController {
	protected Logger logger = LoggerFactory.getLogger(this.getClass());

	protected ManagerVo getUser() {
		return (ManagerVo) SecurityUtils.getSubject().getPrincipal();
	}

	protected String getUserId() {
		return getUser().getUserId();
	}

	protected String getDeptId() {
		return getUser().getDeptId();
	}
}
